package com.test.design.example2.abstractfactory.impl;

import com.test.design.example2.dto.WindowsButton;
import com.test.design.example2.dto.WindowsDialog;
import com.test.design.example2.dto.cxcp.Button;
import com.test.design.example2.dto.cxcp.Dialog;
import com.test.design.example2.abstractfactory.UIFactory;

/**
 * @program: design-patternz
 * @description: windows工厂
 * @author: <a href="mailto:zhengjiaming@gtmap.cn">zhengjiaming</a>
 * @create: 2024-12-26 11:43
 **/
public class WindowsFactory implements UIFactory {
    @Override
    public Button createButton() {
        WindowsButton windowsButton = new WindowsButton();
        windowsButton.setYs("白色");
        return windowsButton;
    }

    @Override
    public Dialog createDialog() {
        WindowsDialog windowsDialog = new WindowsDialog();
        windowsDialog.setWz("顶部");
        return windowsDialog;
    }
}
